package com.atguigu.gulimall.product.service;

import com.atguigu.gulimall.product.entity.AttrAttrgroupRelationEntity;
import com.atguigu.gulimall.product.entity.AttrEntity;
import com.atguigu.gulimall.product.vo.AttrGroupWithAttrs;
import com.atguigu.gulimall.product.vo.SkuItemVo;
import com.baomidou.mybatisplus.extension.service.IService;
import com.atguigu.common.utils.PageUtils;
import com.atguigu.gulimall.product.entity.AttrGroupEntity;

import java.util.List;
import java.util.Map;

/**
 * 属性分组
 *
 * @author shujun
 * @email 961624576@qq.com
 * @date 2024-01-12 18:44:30
 */
public interface AttrGroupService extends IService<AttrGroupEntity> {

    PageUtils queryPage(Map<String, Object> params);

    PageUtils queryByCatIdPage(Map<String, Object> params,Long catId);

    List<AttrEntity> getAttrsByAttrGroupId(Long attrgroupId);

    void relationDelete(List<AttrAttrgroupRelationEntity> relationEntities);

    PageUtils noAttrRelation(Map<String, Object> params, Long attrgroupId);

    void saveAttrRelation(List<AttrAttrgroupRelationEntity> relationEntities);

    List<AttrGroupWithAttrs> getAttrGroupWithAttrsByCatelogId(Long catelogId);

    List<SkuItemVo.SpuItemAttrGroupVo> getAttrWithGroupNameBySpuId(Long spuId);
}

